﻿var mongoose = require('mongoose');

var dptInfoSchema = new mongoose.Schema({
    dpt_name: { type: String, unique: true, allowNull: false},
    lastModifyDate: Date
});

dptInfoSchema.pre('save', function (next) {
    this.lastModifyDate = Date.now();
    next();
});

module.exports = dptInfoSchema;